package com.mrzhou.mybatis.base;

import io.swagger.annotations.ApiModelProperty;
import lombok.Getter;
import lombok.Setter;

/**
 * @author qiang.zhou
 */
@Getter
@Setter
public class PageQuery {

    @ApiModelProperty("当前页")
    private Integer current = 1;

    @ApiModelProperty(value = "起始行", hidden = true)
    private Integer page;

    @ApiModelProperty("页面大小")
    private Integer size = 10;

    public Integer getPage() {
        return this.page = (this.current - 1) * this.size;
    }

}
